<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>

<body>

    <script>
        const convert = (num) => {
            // // TODO: 请在此处完善代码
            let letters = '';
            let time = parseInt(num / 26);
            // 65 => A

            while ((time && (num > 0))) {
                let letterNum = num % 26;
                num -= 26;
                console.log(num);
                let letter = String.fromCodePoint(letterNum + 64);
                letters += letter;
                time--;
            }
            console.log(letters);
        }

        convert(12);
    </script>
</body>

</html>